package com.youlian.cloud.user.controller;

import com.youlian.cloud.core.response.ObjectResponseModel;
import com.youlian.cloud.user.service.request.UserRequest;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author liuhx
 * @create 2019/07/30 11:08
 * @email liuhx@elab-plus.com
 **/
@Slf4j
@RestController
@RequestMapping("producer")
@Api(value = "网关路由", description = "网关路由", tags = {"网关路由"})
public class ProducerController {

    @GetMapping(value = "hi",produces = "application/json;charset=UTF-8")
    @ApiOperation(value = "测试路由", notes = "测试路由", nickname = "刘海啸")
    public ObjectResponseModel hi(@RequestParam UserRequest userRequest) {
        ObjectResponseModel response = new ObjectResponseModel();
        log.info("[client服务] [hi方法]收到请求");
        response.setSingle(userRequest);
        return response;
    }
}
